<!DOCTYPE html>
<html lang="zh-CN">

<head>
  <?php include 'inc/head.php'; ?>
</head>

<body>
  <?php include 'inc/header.php'; ?>

  <div class="container">

    <?php
    echo form_create(
      ['action' => M('admin', 'slideshow', 'edit_action', $this->id)],
      [
        ['type' => 'text', 'label' => '名称', 'key' => 's_name', 'required' => 'required'],
        [
          'type' => 'select', 'label' => '属于', 'key' => 's_parent', 'value' => '<option value="global" ' . ($row['s_parent'] == 'global' ? 'selected="selected"' : '') . '>全局</option> <option value="mobile" ' . ($row['s_parent'] == 'mobile' ? 'selected="selected"' : '') . '>手机端</option> <option value="index"' . ($row['s_parent'] == 'index' ? 'selected="selected"' : '') . '>首页</option> ' . channel_select_list(0, $row['s_parent']), 'html' => true
        ],
        ['type' => 'upload_img', 'label' => '图片', 'key' => 's_picture', 'required' => 'required'],
        ['type' => 'text', 'label' => '链接地址', 'key' => 's_link', 'value' => 'http://'],
        ['type' => 'text', 'label' => '排序', 'key' => 's_order', 'value' => 100, 'required' => 'required'],
        ['type' => 'submit', 'label' => '提交']
      ],
      ['幻灯编辑'],
      $row
    );
    ?>

  </div>

  <?php include 'inc/footer.php'; ?>

</body>

</html>